// treesetapp comment
package com.collections;

import java.util.TreeSet;

public class TreeSetApp {

		public static void main(String[] args) {
		TreeSet t=new TreeSet();
		TreeSet t1=new TreeSet();
		t.add(50);
		t.add(4);
		t.add(3);
		t.add(6);
		t.add(3);
		t.add(7);
		t.add(1);
		System.out.println("treeset.."+t);
		
		System.out.println("treeset.."+t.ceiling(5));
		System.out.println("treeset.."+t.toString());
		System.out.println("treeset.."+t.comparator());
		System.out.println("treeset.."+t.contains(5));
		System.out.println("treeset.."+t.containsAll(t1));
		System.out.println("treeset.."+t.tailSet(4,false));
		//System.out.println("treeset.."+t.pollLast());
		//System.out.println("treeset.."+t);
		//System.out.println("treeset.."+t.pollFirst());
		//System.out.println("treeset.."+t);
		System.out.println("treeset.."+t1.pollFirst());
		
		System.out.println("treeset.."+t.subSet(3, 7));
		System.out.println("treeset.."+t.descendingSet());
		
		System.out.println("treeset.."+t.last());
		//System.out.println("treeset.."+t.lower(t));
		
		
		}
}
